package horncomb.bpm.task.entity;

import horncomb.bpm.task.core.TaskComment;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * @author Daniel
 */
@Entity
@Table(name = "BPM_TASKCMMT")
public class DefaultTaskCommentEntity implements Serializable, TaskComment {
	private static final long serialVersionUID = -7009205236313741021L;

	private String id;
	private String taskInstanceId;
	private Date createdDate;
	private String comment;

	/**
	 * {@inheritDoc}
	 */
	@Id
	@Column(name = "ID_")
	public String getId() {
		return id;
	}

	/**
	 * @param id
	 *            the id to set
	 */
	public void setId(String id) {
		this.id = id;
	}

	/**
	 * {@inheritDoc}
	 */
	@Column(name = "TASK_INST_")
	public String getTaskInstanceId() {
		return taskInstanceId;
	}

	/**
	 * @param taskInstanceId
	 *            the taskInstanceId to set
	 */
	public void setTaskInstanceId(String taskInstanceId) {
		this.taskInstanceId = taskInstanceId;
	}

	/**
	 * {@inheritDoc}
	 */
	@Column(name = "CREATE_")
	public Date getCreatedDate() {
		return createdDate;
	}

	/**
	 * @param createdDate
	 *            the createdDate to set
	 */
	public void setCreatedDate(Date create) {
		this.createdDate = create;
	}

	/**
	 * {@inheritDoc}
	 */
	@Column(name = "COMMENT_")
	public String getComment() {
		return comment;
	}

	/**
	 * @param comment
	 *            the comment to set
	 */
	public void setComment(String comment) {
		this.comment = comment;
	}
}
